package iset.coverageanalyzer.output;

import iset.coverageanalyzer.misc.KeyValuePair;

import java.util.ArrayList;
import java.util.HashMap;

public class JPFInfo {
	
	private ArrayList<String> keys = null;
	private HashMap<String,String> kvs = null;
	
	public JPFInfo(){
		keys = new ArrayList<String>();
		kvs = new HashMap<String,String>();
	}
	
	public int addKeyValue(String key, String value){
		keys.add(key);
		kvs.put(key, value);
		return kvs.size();
	}
	
	public int getSize(){
		return keys.size();
	}
	
	public KeyValuePair getKVP(int index){
		String key = keys.get(index);
		return new KeyValuePair(key,kvs.get(key));
	}
	
	public void standardInit(){
		this.addKeyValue("listener", "gov.nasa.jpf.symbc.SymbolicListener");
		this.addKeyValue("vm.storage.class", "nil");
		this.addKeyValue("search.multiple_errors", "true");
		this.addKeyValue("classpath", ".");
	}
}
